/*
*  Copyright 2020-2021 Li Fei
*
*  Licensed under the Apache License, Version 2.0 (the "License");
*  you may not use this file except in compliance with the License.
*  You may obtain a copy of the License at
*
*  http://www.apache.org/licenses/LICENSE-2.0
*
*  Unless required by applicable law or agreed to in writing, software
*  distributed under the License is distributed on an "AS IS" BASIS,
*  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
*  See the License for the specific language governing permissions and
*  limitations under the License.
*/
package com.pengshun.modules.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonView;
import com.pengshun.modules.common.Level;
import com.pengshun.modules.common.ReslutView;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.persistence.*;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
* @description /
* @author lifei
* @date 2020-11-12
**/
@Entity
@Data
@Table(name="ps_merchant_coal")
public class MerchantCoal implements Serializable {

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "merchant_coal_id")
    @ApiModelProperty(value = "商户煤炭id")
    private Long merchantCoalId;

    @Column(name = "user_id")
    private Long userId;

    @Column(name = "merchant_name")
    private String merchantName;

    @Column(name = "merchant_id")
    private Long merchantId;
    private Long categoryId;
    private String categoryName;
    private String coalCategoryName;
    private Long coalCategoryId;
    private Integer  lowNumber;
    private BigDecimal releaseNumber;
    //产地
    private String producingArea;
    //交割地
    private String delivery;

    private String deliveryId;
    private Integer lookNumber;
    private String deliveryWay;
    //煤炭工艺
    private String coalTechnologyName;
    //煤炭工艺编码
    private String coalTechnologyCode;
    private Date overTime;
    @JsonView(ReslutView.aView.class)
    private String coalPic;
    private String coalPicTwo;
    private String coalPicThree;
    private BigDecimal volatilization;
    private String isTax;


    @Column(name = "mine_mouth_id")
    private Long mineMouthId;

    @Column(name = "mine_mouth_name")
    private String mineMouthName;

    @Column(name = "coal_id")
    private Long coalId;

    @Column(name = "coal_name")
    private String coalName;

    @Column(name = "status",nullable = false)
    @ApiModelProperty(value = "状态(0停用，1正常，2已删除))")
    private Integer status;

    //发布状态(0未发布，1审核中，2已发布，3已驳回)
    private Integer issueStatus;

    @Column(name = "sell_price",nullable = false)
    @ApiModelProperty(value = "销售价格")
    private BigDecimal sellPrice;

    @Column(name = "coal_price",nullable = false)
    @ApiModelProperty(value = "煤炭价格")
    private BigDecimal coalPrice;

    @Column(name = "coal_number")
    private BigDecimal coalNumber;

    @Column(name = "price_unit")
    @ApiModelProperty(value = "单位")
    private String priceUnit;


    @Column(name = "create_time")
    @ApiModelProperty(value = "创建时间")
    private Date createTime;

    @Column(name = "create_by")
    @ApiModelProperty(value = "创建人")
    private String creatBy;

    @Column(name = "update_time")
    @ApiModelProperty(value = "更新时间")
    private Date updateTime;

    @Column(name = "update_by")
    @ApiModelProperty(value = "更新人")
    private String updateBy;

    @ApiModelProperty(value = "发热量")
    private Integer coalCalorific;
    private String wholeWater;
    private String nsValue;
    private String serchHuifen;
    private String kfValue;
    private String sfValue;
    private String gfValue;
    private String allSulphur;
    private String jzValue;
    private String gtValue;
    private String kwValue;
    private String swValue;

    private String linkman;
    private String linkmanPhone;


    @Column(name = "laboratory_time")
    @ApiModelProperty(value = "化验时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    private Date laboratoryTime;

    @Column(name = "issue_time")
    @ApiModelProperty(value = "发布时间")
    private Date issueTime;

    @Column(name = "laboratory_bill_pic")
    @ApiModelProperty(value = "化验单图片")
    private String laboratoryBillPic;

    @Column(name = "laboratory_company")
    @ApiModelProperty(value = "化验单单位")
    private String laboratoryCompany;

    @Column(name = "remark")
    @ApiModelProperty(value = "备注")
    private String remark;

    @Column(name = "is_show")
    @ApiModelProperty(value = "商品上架时间状态（0-下架；1-上架）")
    private Integer isShow;

    private Integer level = Level.ZERO_STATUS;

    private Integer sort;



}